Developer Documentation
PATH  WebObjects 4.5 Documentation > Getting Started With Direct to Java Client

   

Building and Running the Application

Building and running the application is just like building and running any other Java Client application. Simply perform the following steps.

  1. Build the application.

    Choose Tools Project Build Build. This opens the Build Project panel and builds the application.

  2. Configure the application's launch options.

    Choose Tools Launcher Launcher. This opens the Launch panel. Click the check mark button to open the Launch Options panel. In the lower half of the window, ensure that the Arguments tab is selected. Click Add. Type the following, substituting values appropriate for your environment:

    On MacOS X Server:

    -WOPort 8888 -WOAutoOpenInBrowser NO -NSProjectSearchPath '(/tmp)'

    On Windows:

    -WOPort 8888 -WOAutoOpenInBrowser NO -NSProjectSearchPath '(C:/tmp)'

    The launch arguments are used as follows:

  3. Start the server application.

    On the Launch panel, click the Launch button (the left most button).

  4. Start the client application.

    In a shell, start the client as an application.

    On MacOS X Server:

    java -classpath "/Local/Library/Frameworks/
    BusinessLogicClient.framework/WebServerResources/Java:/System/
    Library/Java/eojavaclient.jar:/System/Library/Frameworks/
    JavaVM.framework/Classes/classes.jar:/System/Library/
    Frameworks/JavaVM.framework/Classes/awt.jar:/System/Library/
    Frameworks/JavaVM.framework/Classes/swingall.jar"
    com.apple.client.eoapplication.EOApplication -applicationURL
    http://localhost:8888/cgi-bin/WebObjects/D2JCTutorial

    On Windows (substituting your $NEXT_ROOT if necessary):

    java -classpath "C:\Apple\Local\Library\Frameworks\
    BusinessLogicClient.framework\WebServerResources\Java;C:\Apple\
    Library\Java\eojavaclient.jar;C:\Apple\Library\JDK\lib\
    classes.zip;C:\Apple\Library\JDK\lib\swingall.jar"
    com.apple.client.eoapplication.EOApplication -applicationURL
    http://localhost:8888/cgi-bin/WebObjects/D2JCTutorial

Warning:  Do not put C:\Apple\Library\Frameworks\JavaVM.framework\Classes\awt.jar in your classpath on Windows. It is required on MacOS X Server, but you shouldn't include it on other platforms.

Note:  For the final deployment of the client application, you should build a jar file (or a small number jar files) containing the classes used by the application (classes in the Java Client packages, classes in swingall.jar, and your custom classes). Then to start the client application, you list only those jar files in the classpath.

If the Client Application Doesn't Start

If the Application Has No Windows


© 1999 Apple Computer, Inc. – (Draft. Last updated 05 Jan 00)